﻿@model Survey.Common.Models.Services.IArticleModel

@this.CreateForm()

@AddControls(
    new Fieldset("w70p mh100 ", Str.Business.Common.Identification)
    {
        new DefinitionList(PercentForLabel.p30)
        {
            new TextOrInput(maxLength: 100)
                .SetSourceProperty(() => Model.Filter.Description),

            new TextOrInput(maxLength: 100)
                .SetSourceProperty(() => Model.Filter.Title),

            new TextOrInput(maxLength: 100)
                .SetSourceProperty(() => Model.Filter.Text),

            new TextOrInput(maxLength: 10)
                .SetSourceProperty(() => Model.Filter.IdExact),
        }
    },
    new Fieldset("w70p mh100 ", Str.Business.Common.Description)
    {
        new DefinitionList(PercentForLabel.p30)
        {
            new AsyncComboBox()
                .SetSourceProperty(() => Model.Filter.ArticleCategory)
                .SetComboBoxShowEmpty(true),

            new AsyncComboBox()
                .SetSourceProperty(() => Model.Filter.ArticleGroup)
                .SetComboBoxShowEmpty(true),

            new TextOrInput(maxLength: 20)
                .SetSourceProperty(() => Model.Filter.ReleaseFrom),

            new TextOrInput(maxLength: 20)
                .SetSourceProperty(() => Model.Filter.ReleaseTo),
        }
    })

@AddControls(
    new AdjustListView
    {
        Type = AdjustListViewType.Fieldset,
        CssClassName = "w70p mh75"
    }
)

@this.CloseForm()